package com.xioz.android;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.graphics.g2d.BitmapFont;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.graphics.g2d.TextureRegion;
import com.badlogic.gdx.math.Vector3;

/**
 * GameAdvanceMenu Class
 * A MenuType that carries the word game to play
 * 
 * @author Zong Xiong
 */
public class GameAdvanceMenu implements MenuType {
	// stores the word game to play
	Screen advancingScreen;
	
	
/***************************************************
 * Public Methods
 ***************************************************/
	
	/**
	 * Basic Constructor
	 * constructs a gameAdvanceMenu of a particular word game
	 * @param selection, word game to load
	 */
	public GameAdvanceMenu(int selection) {
		// depending on the selection we load the word game
		switch(selection) {
		case 1:
			advancingScreen = new NormalGameScreen();
			break;
		case 2:
			advancingScreen = new SurvivalGameScreen();
			break;
		case 3:
			advancingScreen = new TimeAttackGameScreen();
			break;
		case 4:
			advancingScreen = new DestroyerGameScreen();
			break;
		default:
			advancingScreen = new NormalGameScreen();
			break;
				
		}
	}

	/** {@inheritDoc} */
	@Override
	public void draw(SpriteBatch batch, TextureRegion inactiveButton,
			TextureRegion activeButton, TextureRegion textBar,
			TextureRegion grayBar, BitmapFont menuFont, BitmapFont textFont) {
		// we do nothing here, since this is only a carrier
		
	}

	/** {@inheritDoc} */
	@Override
	public MenuType getPreviousMenu() {
		// return nothing here, since this is only a carrier
		return null;
	}

	/** {@inheritDoc} */
	@Override
	public MenuType getMenuOption(Vector3 pointer) {
		// return nothing here, since this is only a carrier
		return null;
	}

	/** {@inheritDoc} */
	@Override
	public void setVisible(boolean visibility) {
		// do nothing here, since this is only a carrier

	}

	/** {@inheritDoc} */
	@Override
	public boolean isVisible() {
		// return nothing, since this is only a carrier
		return false;
	}

	/**
	 * getWordGame
	 * returns the word game that was selected
	 * 
	 * @return word game selected
	 */
	public Screen getWordGame() {
		return advancingScreen;
	}
}
